//
//  UIView+SLAddTapShowAnimation.h
//  shunlianPower2
//
//  Created by 陈镇 on 2020/3/28.
//  Copyright © 2020 顺联网络. All rights reserved.
//

#import <UIKit/UIKit.h>
#import "SLTapView.h"
NS_ASSUME_NONNULL_BEGIN

@protocol SLAddTapShowAnimationProtocal <NSObject>

@optional
//在self中实现这个方法，可以控制有回调
-(void)sl_AddTapShowAnimationViewWillHidden;
-(void)sl_AddTapShowAnimationViewDidHidden;

-(void)sl_AddTapShowAnimationViewWillShow;
-(void)sl_AddTapShowAnimationViewDidShow;

@end


@interface SLTapView (SLAddTapShowAnimation)<UIGestureRecognizerDelegate>

/** 显示隐藏的view */
@property(nonatomic,strong) UIView *showHiddenSubView;
/** 底部边距 */
@property (nonatomic, assign) CGFloat bottomMargin;
/** 是否展示动画*/
@property (nonatomic, assign) BOOL sl_animation;
//禁止点击背景 隐藏弹框，默认不禁止
@property(nonatomic,assign) BOOL disableCanClickBackgroundDismiss;
//添加没响应的点击事件
-(void)sl_addNoResponseTap;


/*
给一个视图 添加点击事件，隐藏子视图 并且移出自身
 */
-(void)sl_addDisMissTapAnimationView:(UIView *)subView;

/*
 让self某个子视图显示在 self的底部
 */

-(void)sl_showBottomSubView:(UIView *)subView;
-(void)sl_showBottomSubView:(UIView *)subView animation:(BOOL)animation;

//隐藏本视图
-(void)sl_disMissView;

@end

NS_ASSUME_NONNULL_END
